home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / language / xlspedit.arc / READ.ME < prev   
Lisp/Scheme  |  1980-01-04  |  4KB  |  134 lines

  1.  
  2.  
  3.  
  4.  
  5.                  Some notes on the XLISP EDITOR:
  6.  
  7.      I don't claim any copyright to the editor, and I actually
  8. welcome any alterations or additions you may want to make to it.
  9. In fact, to make things extra easy, I provide the following:
  10.  
  11. This editor works on the basis that:
  12.  
  13. (setq a 'b)
  14. <returns>
  15. b
  16.  
  17. (setq b '(x y z))
  18. <returns>
  19. (x y z)
  20.  
  21. So that:
  22. (eval a)
  23. <returns>
  24. (x y z)
  25.  
  26. In the editor program, "curloc" is used where you see "a" above.
  27.  
  28.      To create your own functions you need only define your new
  29. function and then add its name to "comset" which contains the list
  30. of available commands.  To rename the functions, you need only
  31. change the current function name to what you want, and change it's
  32. corresponding entry in "comset".
  33.  
  34.  
  35. On Using the Editor:
  36.  
  37.      Creating new functions:
  38.      If you want to create a new function, you will have to create
  39. it outside the editor.  A good way to start of a new function is
  40. to enter the following: (defun <fname> (<parameters>))
  41. For example, if I wanted to create a function that computed the
  42. factorial of a number, I would type in the following:
  43.  
  44. (defun fact (x))
  45.  
  46. followed by:
  47.  
  48. (ef 'fact)
  49.  
  50.  
  51.      Bugs:
  52.      I have tested the editor on a variety of lisp functions and
  53. taken care of what errors appeared.  Of course, I am sure that
  54. those of you out there who use my little creation with any
  55. regularity will certainly find a plethora of new ones.  In my
  56. defense, I can only say this:  Tell me what you find, and I'll
  57. incorporate the fix into a later version.
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.                               - 1 -
  67.  
  68.  
  69.  
  70.      Insertion:
  71.      You may have noticed that insertions may only be made after
  72. elements.  This would seem to make it impossible to insert
  73. anything at the very beginning of a list... it doesn't.  However,
  74. short of writing you own insertion function, you should try the
  75. following:  "pre" some dummy atom to the first item of the list,
  76. then "rmp" the parentheses, then insert what you want, then delete
  77. the dummy atom.  It's really not as involved as it sounds, and
  78. spares me the headache of trapping for all the special cases that
  79. would pop up otherwise.
  80.  
  81.      Moving:
  82.      The variable "sxpr", which is used by the move function, is
  83. only altered when something is "Cut" to it by "mv c".  This allows
  84. you to make multiple "Paste"s using "mv p", and even allows you to
  85. cut from one function definition and paste to another.  To make
  86. this possible, one potential avenue for error was purposely left
  87. un-trapped.  So please, don't try to paste anything until you have
  88. cut at least once.  If you do, I guarantee the program will crash.
  89.  
  90.      Entering commands:
  91.      Whether or not it is obvious, more than one command may be
  92. entered at the "Edit:  >" prompt.  For example, "d d a a d a a"
  93. will get you quickly into the heart of the function you're
  94. editing.
  95.  
  96.      Macros:
  97.      While I didn't include any, you may want to add some macros.
  98. For instance, the command series "d d a a d a a" could be
  99. incorporated into a new function called "dth" for Descend To Heart
  100. of the function.  Note that in my next revision I will have
  101. redesigned a number of the editor's functions so that creating
  102. macros will be easier.
  103.  
  104.      Things to stay away from:
  105.      The following variables are destructively altered by the
  106. editor program:  sf, base, curloc, comset, sxpr, tmp, tmp2; so don't
  107. use them in your own programs.  Additionally, if you choose to use
  108. the save function provided, you should steer clear of the
  109. following variables:  fp, bse, nmf, tpe, prms, rst.
  110.  
  111.  
  112.      Things to look forward to in upcoming revisions:
  113.  
  114.      A viewing toggle that causes only a screen size portions of
  115. the list being edited to be displayed.  (Useful for those BIG
  116. lists.)
  117.      Tab stops in combination with an improved "pp" function that
  118. allows you to pretty-print a larger section of the list without
  119. having it scroll off the screen.
  120.      An improved version of GOTO.  I have tried a number of ways
  121. already, but so far it refuses to comply.
  122.      An insert function that inserts in front of elements.
  123.      Improved advance, backup, and descend functions, that let you
  124. move in leaps and bounds if you so desire.
  125.      Revision of a number of functions to facilitate macro
  126. construction.
  127.  
  128.  
  129.  
  130.  
  131.  
  132.                               - 2 -
  133.  
  134.